#include "Monster.h"

using namespace luabridge;

bool Monster::RegistLuaClass(lua_State* state)
{
	getGlobalNamespace(state)
		.beginNamespace("_G")
		.deriveClass<Monster, Creature>("LuaMonster")		// 注意：派生类与非派生类区别

		.addFunction("GetAttr", &Monster::LuaGetAttr)

		.endClass()
		.endNamespace();
	return true;
}

int32_t Monster::LuaGetAttr(uint32_t CANum)
{
	return GetAttr(CANum);
}

